package com.qd.common.panda.domain.entity.rule;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.math.BigDecimal;

/**
 * 有起价按小时有封顶计费，如“前两小时5元，以后每小时3元，24小时封顶收费15元
 * {
 * "startHour": 2,
 * "startPrice": 500,
 * "price": 300,
 * "capTime": 24,
 * "capPrice": 1500
 * }
 */
@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = true)
public class Rule3DTO extends Rule2DTO {
    private Integer capTime;
    private BigDecimal capPrice;

    @Override
    public void freeData() {
        this.capTime = null;
        this.capPrice = null;
        super.freeData();
    }
}